package com.lj.service;

import com.lj.dao.WarehouseDao;
import com.lj.entity.Warehouse;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>Title: </p>
 * <p>Description:</p>
 *
 * @author <a href="mailTo:bingxuewulei@outlook.com">wanglei</a>
 * @version 1.0
 * @history: Created by wanglei on  2021/11/14
 */
@Service
public class WarehouseServiceImpl implements WarehouseService {
    @Resource
    WarehouseDao warehouseDao;


    @Override
    public List<Warehouse> queryAllWarehouse() {
        return warehouseDao.queryAllWarehouse();
    }

    @Override
    public int addWarehouse(Warehouse warehouse) {
        return warehouseDao.addWarehouse(warehouse);
    }

    @Override
    public Warehouse findWarehouseDetail(int id) {
        return warehouseDao.findWarehouseDetail(id);
    }

    @Override
    public int deleteWarehouse(int id) {
        return warehouseDao.deleteWarehouse(id);
    }

    @Override
    public int updateWarehouse(Warehouse warehouse) {
        return warehouseDao.updateWarehouse(warehouse);
    }
}
